package db7;

public class Literature extends Student{
    double yanjiang;
    double zuopin;
    double mtest;
    double ttest;
    public Literature(int sno,String name,String sex,int age,double yanjiang,double zuopin,double mtest,double ttest){
        super(sno,name,sex,age);
        this.yanjiang=yanjiang;
        this.zuopin=zuopin;
        this.mtest=mtest;
        this.ttest=ttest;
    }
    @Override
    public double getGrade(){
        double grade =0;
        grade=yanjiang*0.35+mtest*0.15+ttest*0.35;
        return grade;
    }
}
